package Test.park;

//import java.math.BigDecimal;
import java.util.Date;

public class ParkRecordModel {
	
	private int parkId;
	private String carId;
	private Date startTime;
	private Date endTime;
	private double money;
	public ParkRecordModel(int parkId, String carId, Date startTime, Date endTime, double money) {
		super();
		this.parkId = parkId;
		this.carId = carId;
		this.startTime = startTime;
		this.endTime = endTime;
		this.money = money;
	}
	public double getMoney() {
		return money;
	}
	public void setMoney(double money) {
		this.money = money;
	}
	@Override
	public int hashCode() {
		final int prime = 31;
		int result = 1;
		result = prime * result + ((carId == null) ? 0 : carId.hashCode());
		result = prime * result + parkId;
		return result;
	}
	@Override
	public boolean equals(Object obj) {
		if (this == obj)
			return true;
		if (obj == null)
			return false;
		if (getClass() != obj.getClass())
			return false;
		ParkRecordModel other = (ParkRecordModel) obj;
		if (carId == null) {
			if (other.carId != null)
				return false;
		} else if (!carId.equals(other.carId))
			return false;
		if (parkId != other.parkId)
			return false;
		return true;
	}

	public ParkRecordModel(int parkId, String carId) {
		super();
		this.parkId = parkId;
		this.carId = carId;
	}
	public ParkRecordModel(int parkId, String carId, Date startTime, Date endTime) {
		super();
		this.parkId = parkId;
		this.carId = carId;
		this.startTime = startTime;
		this.endTime = endTime;
	}
	public int getParkId() {
		return parkId;
	}
	public void setParkId(int parkId) {
		this.parkId = parkId;
	}
	public String getCarId() {
		return carId;
	}
	public void setCarId(String carId) {
		this.carId = carId;
	}
	public Date getStartTime() {
		return startTime;
	}
	public void setStartTime(Date startTime) {
		this.startTime = startTime;
	}
	public Date getEndTime() {
		return endTime;
	}
	public void setEndTime(Date endTime) {
		this.endTime = endTime;
	}
	

}
